
<!DOCTYPE html>
<html>
<head>
<base href="${basePath}">
<meta charset="UTF-8">
<title>首页</title> $!{include("import_js_css.html")}
<script type="text/javascript" src="${assetsPath}/js/jquery/jquery.mb.browser.js"></script>
<!-- #set(PaginatedList<HomePageTaskRecord> pl) -->

<!--
		#set(
		pager = pl.pager,
		totalResults = pager.getCountOfTotalResults(),
		totalPages = pager.getCountOfTotalPages() * 1,
		pageSize = pager.pageSize,
		pageNo = pager.pageNo,
		prePageNo = pager.getPrevPageNo(),
		nextPageNo = pager.getNextPageNo(),
		m =0,
		n =0
		)
		#set(date = new Date().format("yyyy-MM-dd"))
-->
<script type="text/javascript">
	$(function() {
		//判断是否ipad
		if(jQuery.browser.ios){//表示是ios设备
			window.location.href = "yueyogaPadAdmin/index.jhtml";//跳转到pad页面
			return;
		}
		
		$("#btn_exp_task").click(function() {
			window.location.href = "yueyogaAdmin/searchTasks.jhtml?aboutToExpiry=1&display=block";
		});
		var initOrderCol = "${initOrderCol}";
		var initOrder = "${initOrder}";
		
		$(".order-col[data="+initOrderCol+"]").attr("order",initOrder);
		if(initOrder == "desc") {
			$(".order-col[data="+initOrderCol+"] .down").show();
			$(".order-col[data="+initOrderCol+"] .up").hide();
		} else {
			$(".order-col[data="+initOrderCol+"] .up").show();
			$(".order-col[data="+initOrderCol+"] .down").hide();
		}
		
		//列点击排序
		$("#task-list .order-col").click(function(){
			var col = $(this).attr("data");
			var order = $(this).attr("order");
			
			if(order == "desc") {
				order = "asc";
			} else {
				order = "desc";
			}
			
			$("#orderform #ordercol").val(col);
			$("#orderform #order").val(order);
			$("#orderform").submit();
		});
	});

	function changePage(value) {
		var totalPages = '${totalPages}';
		value = value * 1;
		if (value > totalPages) {
			value = totalPages;
		} else if (value < 1) {
			value = 1;
		}else{
			goToPage(value);
		}
		$("#txtPageNumber").val(value);
	}
	function goToPage(pageNo) {
		$("#hidPageNo").val(pageNo);
		window.location.href = "yueyogaAdmin/main.jhtml?pageNo="+pageNo;
	}
</script>
</head>
<body>
	$!{include("header.html")}
	<div class="container menu_all">
		<div class="panel panel-info main_act panel-border">
			<div class="panel-heading search-result-title">
				<h3 class="panel-title">快捷入口</h3>
			</div>
			<div id="div_search_member" class="main_act_div">
				<a href="yueyogaAdmin/searchMember.jhtml"><img alt="" src="${resourcePath}/images/search_contact.png">搜索会员</a>
			</div>
			<div id="div_search_clazz" class="main_act_div">
				<a href="yueyogaAdmin/searchClass.jhtml"><img alt="" src="${resourcePath}/images/search_clazz.png">搜索班级</a>
			</div>
			<div id="div_search_goods" class="main_act_div">
				<a href="yueyogaAdmin/searchTasks.jhtml"><img alt="" src="${resourcePath}/images/search_goods.png">搜索任务</a>
			</div>
			<div id="div_add_member" class="main_act_div">
				<a href="yueyogaAdmin/toAddMember.jhtml"><img alt="" src="${resourcePath}/images/add_member.png">创建会员</a>
			</div>
			<div id="div_add_clazz" class="main_act_div">
				<a href="yueyogaAdmin/toAddClass.jhtml"><img alt="" src="${resourcePath}/images/add_clazz.png">创建班级</a>
			</div>
		</div>
		<div class="panel panel-info main_status" style="background: white;">
			<div class="panel-heading search-result-title">
				<h3 class="panel-title">状态</h3>
			</div>
			<button class="main_btn" id="btn_exp_task" value="1">${expiryCount}</button>
			<label style="color:#428BCA;font-weight:100;">过期任务</label>
		</div>
		<!-- 会员的查询 -->
		<div class="panel panel-info clear main_info panel-border" style="background: white;">
			<div class="panel-heading search-result-title">
				<h3 class="panel-title">会员跟踪</h3>
			</div>

			<div id="div_mms" class="panel-mms">
				<form action="yueyogaAdmin/searchMember.jhtml" method="post">
					<div class="mms-div-top">
						<div>
							<label class="col-sm-1 control-label mms-long-label">账户余额少于</label><input class="form-control" onkeyup="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')" id="syjq" name="syjq" type="text" /><label class="mms-short-label">元</label>
						</div>
						<div>
							<label class="col-sm-1 control-label mms-long-label">会员产品少于</label><input onkeyup="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')" class="form-control" id="syts" name="syts" type="text" /><label class="mms-short-label">天</label>
						</div>
						<div>
							<label class="col-sm-1 control-label mms-long-label">会员产品少于</label><input onkeyup="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')" class="form-control" id="sycs" name="sycs" type="text" /><label class="mms-short-label">次</label>
						</div>
					</div>
					<div class="mms-div-bottom">
						<div class="mms-ml-div">
							<label class="col-sm-1 control-label mms-medium-label">会员</label><input onkeyup="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')" id="mgzts" name="mgzts" class="form-control" type="text" /><label class="mms-ml-label">天未跟踪</label>
						</div>
						<div class="mms-ml-div">
							<label class="col-sm-1 control-label mms-medium-label">正式会员</label><input onkeyup="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')" id="mglts" name="mglts" class="form-control" type="text" /><label class="mms-ml-label">天未到馆</label>
						</div>
					</div>
					<input type="hidden" value="block" name="display"/>
					<div class="mms-search">
						<button type="submit" class="btn btn-default">搜索</button>
					</div>
				</form>
			</div>
		</div>

		<div class="panel panel-info clear main_info panel-border" style="background: white;">
			<div class="panel-heading search-result-title">
				<h3 class="panel-title">活动列表（最近5个）</h3>
			</div>

			<table id="task-list" class="table table-bordered table-hover table-condensed tb" style="text-align: center;">
				<tr class="tb-tr-tit">
					<td style="width:90px;">活动编号</td>
					<td>活动主题</td>
					<td style="width:160px;">场地</td>
					<td class="tb-teacher">教练</td>
					<td class="tb-teacher">助教</td>
					<td class="tb-teacher">负责人</td>
					<td class="tb-time">开始日期</td>
					<td class="tb-time">结束日期</td>
				<tr>
					<!-- #set(List<HomePageLiftClub> lastLiftClubs) -->
					<!-- #for(HomePageLiftClub lc : lastLiftClubs) -->
				<tr>
					<td><a href="yueyogaAdmin/toLiftClubDetail.jhtml?id=${lc.id}">${lc.id}</a></td>
					<td><a href="yueyogaAdmin/toLiftClubDetail.jhtml?id=${lc.id}">${lc.name}</a></td>
					<td>${lc.place}</td>
					<td>${lc.mainTeacher}</td>
					<td>${lc.assistant}</td>
					<td>${lc.officer}</td>
					<td>${lc.startdate.substring(0,16)}</td>
					<td>${lc.enddate.substring(0,16)}</td>
				</tr>
				<!--#end-->
			</table>
		</div>

		<div class="panel panel-info main_info panel-border" style="background: white;">
			<div class="panel-heading search-result-title">
				<h3 class="panel-title">任务列表</h3>
			</div>

			<!--#if(pl)-->
			<table id="task-list" class="table table-bordered table-hover table-condensed tb" style="text-align: center;">
				<tr class="tb-tr-tit">
					<td style="width:90px;">工作安排</td>
					<td class="tb-teacher"><div class="order-col" data="dqsj" order="desc" style="cursor: pointer;">
							<span>到期时间</span><b class="caret down"></b><b class="caret-top up" style="display: none;"></b>
						</div></td>
					<td>会员编号</td>
					<td class="tb-teacher">姓名</td>
					<td class="tb-teacher">手机号</td>
					<td class="tb-teacher"><div class="order-col" data="xxly" order="desc" style="cursor: pointer;">
							<span>信息来源</span><b class="caret down"></b><b class="caret-top up" style="display: none;"></b>
						</div></td>
					<td class="tb-teacher"><div class="order-col" data="zt" order="desc" style="cursor: pointer;">
							<span>会员状态</span><b class="caret down"></b><b class="caret-top up" style="display: none;"></b>
						</div></td>
					<td class="tb-time"><div class="order-col" data="zzt" order="desc" style="cursor: pointer;">
							<span>会员子状态</span><b class="caret down"></b><b class="caret-top up" style="display: none;"></b>
						</div></td>
					<td class="tb-time">创建时间</td>
				<tr>

					<!--#for(HomePageTaskRecord record : pl)-->
				<tr>
					<td>${record.gzap}</td>
					<td>${record.dqsj}</td>
					<td><a href="yueyogaAdmin/toMemberTask.jhtml?id=${record.hybh}">${record.hykh}</a></td>
					<td><a href="yueyogaAdmin/toMemberTask.jhtml?id=${record.hybh}">${record.hyxm}</a></td>
					<td><a href="yueyogaAdmin/toMemberTask.jhtml?id=${record.hybh}">${record.hysjh}</a></td>
					<td>
						<!-- #if(record.xxly=='81') --> 电话打入 <!-- #else(record.xxly=='82') --> 主动拜访 <!-- #else(record.xxly=='83') --> 数据库 <!-- #else(record.xxly=='84') --> 线上活动 <!-- #else(record.xxly=='85') --> 线下活动 <!-- #else(record.xxly=='86') --> 其他 <!-- #else--> &nbsp; <!-- #end -->
					</td>
					<td>${record.hyzt}</td>
					<td>${record.hyzzt}</td>
					<td>${record.cjsj}</td>
				</tr>
				<!--#end-->
			</table>
			<div class="div_page main_div_page">
				<ul class="pagination">
					<li><a href="javascript:void(0)" onclick="goToPage(1)">首页</a></li>
					<!-- #if(pageNo==1) -->
					<li class="disabled"><a href="javascript:void(0)">上一页</a></li>
					<!-- #else -->
					<li><a href="javascript:void(0)" onclick="goToPage(${prePageNo})">上一页</a></li>
					<!-- #end -->
					<!-- #if(pageNo==totalPages) -->
					<li class="disabled"><a href="javascript:void(0)">下一页</a></li>
					<!-- #else -->
					<li><a href="javascript:void(0)" onclick="goToPage(${nextPageNo})">下一页</a></li>
					<!-- #end -->
					<li><a href="javascript:void(0)" onclick="goToPage(${totalPages})">尾页</a></li>
					<li><a>第<input id="txtPageNumber" value="${pageNo}" onkeyup="this.value=this.value.replace(/\D/g,'')" onblur="changePage(this.value)" type="text" />页&nbsp;~&nbsp;共 ${totalPages}&nbsp;页/${totalResults}条
					</a></li>
				</ul>
			</div>
			<!-- #else -->
			<div class="panel-body">没有符合条件的数据</div>
			<!-- #end -->
		</div>
	</div>
	<form id="orderform" action="yueyogaAdmin/main.jhtml" method="post">
		<input id="ordercol" name="ordercol" type="hidden"> <input id="order" name="order" type="hidden">
	</form>
</body>

<script type="text/javascript">
$(function(){
	$("#syts").focus(function(){
			$("#sycs").val("");
	});
	$("#sycs").focus(function(){
			$("#syts").val("");
	});
});
</script>
</html>